package com.itcam.cm.manager.mapper;

import com.itcam.cm.model.dto.system.SysUserDto;
import com.itcam.cm.model.entity.system.SysUser;

import java.util.List;

public interface SysUserMapper {

    /**
     * 根据用户名查询用户数据
     * @param userName
     * @return
     */
    public abstract SysUser selectByUserName(String userName) ;

    SysUser selectSysUserByName(String userName);

    List<SysUser> selectSysUserListByPage(SysUserDto sysUserDto);

    void insertSysUser(SysUser sysUser);

    void updateSysUser(SysUser sysUser);

    /**
     * 分页查询系统用户信息
     * @param sysUserDto
     * @return
     */
    List<SysUser> findByPage(SysUserDto sysUserDto);

    /**
     * 保存系统用户信息
     * @param sysUser
     */
    void saveSysUser(SysUser sysUser);

    /**
     * 保存系统用户信息
     * @param username
     * @return
     */
    SysUser findByUserName(String username);

    /**
     * 根据id删除用户
     * @param userId
     */
    void deleteById(Long userId);
}
